import java.util.ArrayList;
import java.io.*;

/**
 * Project		: Nerdle
 * File 		: distTester.java			Version: 
 * Date 		: 1:28:57 AM
 * Author		: kkopiec
 * Description	:
 *
 */

/**
 * @author kkopiec
 * 
 */
public class distTester {

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		foldocProcessor prc = new foldocProcessor();
		StatisticalAnalyser analyser = new StatisticalAnalyser();
		prc.ReadSrcDictFile();
		ArrayList<String> words = prc.getTerms();
		try {
			FileWriter wrt = new FileWriter("foldoct.dict");
			for (String term : words) {
				System.out.println(term);
				wrt.write(term + "\n");
			}
			wrt.close();
		} catch (IOException ex) {
			System.out
					.println("ERR: Something went terribly wrong during writing processed dictionary into the file !!");
			ex.printStackTrace();
		}
		analyser.analyze(words);
		analyser.displayAnalysis();

	}

}
